In the pipe connector (quick connector) disclosed in patent document 1 (JP-A No. 2005-172161), a top hat that regulates the position of a sealing O-ring disposed in the pipe connector and a retainer that retains a pipe attached to the pipe connector are separate bodies.